From fddcfcd6c810beaa557a7dee5da36b1f7f9dacf6 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ball=C3=B3=20Gy=C3=B6rgy?= Date: Thu, 10 Apr 2025 00:28:43 +0200 Subject: [PATCH] extensions-app: Don't create window in startup phase This fixes the problem that the process does not exit after timeout when running as GApplication service. Part-of: --- subprojects/extensions-app/js/main.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/subprojects/extensions-app/js/main.js b/subprojects/extensions-app/js/main.js index c164c514f..07a5130bb 100644 --- a/subprojects/extensions-app/js/main.js +++ b/subprojects/extensions-app/js/main.js @@ -28,6 +28,10 @@ class Application extends Adw.Application { vfunc_activate() { this._extensionManager.checkForUpdates(); + + if (!this._window) + this._window = new ExtensionsWindow({application: this}); + this._window.present(); } @@ -37,15 +41,13 @@ class Application extends Adw.Application { this.add_action_entries( [{ name: 'quit', - activate: () => this._window.close(), + activate: () => this._window?.close(), }]); this.set_accels_for_action('app.quit', ['q']); this.set_accels_for_action('window.close', ['w']); this._extensionManager = new ExtensionManager(); - - this._window = new ExtensionsWindow({application: this}); } }); -- 2.39.5